// 创建父类 - 非机动车类
class Nonmotorized {
    protected String color;
    protected String brand;

    // 构造方法
    public Nonmotorized(String color, String brand) {
        this.color = color;
        this.brand = brand;
    }

    // 车辆介绍方法（父类）
    public void introduce() {
        System.out.println("这辆车的颜色是" + color + "，品牌是" + brand + "。");
    }
}

// 子类自行车类
class Bike extends Nonmotorized {
    private int seat;

    // 构造方法
    public Bike(String color, String brand, int seat) {
        super(color, brand);
        this.seat = seat;
    }

    // 车辆介绍方法
    public void introduce() {
        super.introduce();
        System.out.println("座位是" + seat + "座");
    }
}

// 子类电动车类
class Electricvehicle extends Nonmotorized {
    private int electricquantity;

    // 构造方法
    public Electricvehicle(String color, String brand, int electricquantity) {
        super(color, brand);
        this.electricquantity = electricquantity;
    }

    // 车辆介绍方法
    public void introduce() {
        super.introduce();
        System.out.println("电量是" + electricquantity + "%");
    }
}

// 子类三轮车类
class Tricycle extends Nonmotorized {
    private int wheel;

    // 构造方法
    public Tricycle(String color, String brand, int wheel) {
        super(color, brand);
        this.wheel = wheel;
    }

    // 车辆介绍方法
    public void introduce() {
        super.introduce();
        System.out.println("车轮是" + wheel);
    }
}

class Main {
    public static void main(String[] args) {
        // 创建各个子类对象
        Nonmotorized t1 = new Bike("蓝色", "崔克蝴蝶", 1);
        Nonmotorized t2 = new Electricvehicle("灰色", "雅迪", 100);
        Nonmotorized t3 = new Tricycle("红色", "金彭", 3);

        // 输出介绍
        System.out.println("自行车介绍:");
        t1.introduce();

        System.out.println("\n电动车介绍:");
        t2.introduce();

        System.out.println("\n三轮车介绍:");
        t3.introduce();
    }
}
